package net.lcheng.service;

import net.lcheng.commons.utils.PageList;
import net.lcheng.model.SysUsers;

public interface SysUsersService {
	/***
	 * 修改登录密码
	 * @param id
	 * @param pwd
     * @return
     */
	int changePassword(long id, String pwd);
	/**
	 * 获取用户
	 * @param username
	 * */
	SysUsers getUserByUsername(String username);
	/**
	 * 获取用户
	 * @param userId
	 * */
	SysUsers getUserByUserId(long userId);
	/**
	 * 删除用户
	 * @param userId
	 * */
	int deleteUser(long userId);

	/**
	 * 获取用户列表
	 * */
	PageList<SysUsers> getUserList(int pageIndex, int pageSize, String name);
	/**
	 * 新增用户
	 * @param userName
	 * @param password
	 * */
	int addUser(String userName, String password, String email, String trueName, String jobNo, String department, String phone, Integer[] roleIds);
	/**
	 * 修改用户
	 * @param userId
	 * @param password
	 * */
	int editUser(long userId, String password, String email, String trueName, String jobNo, String department, String phone, Integer[] roleIds);
}
